Clouseau: Separate write folders for each instance#6059
Conversation
|
I do not think that is needed. The index directories are configured ad hoc via overrides to the configuration by Java properties, i.e. by passing |
That is also a viable option. IMHO it's better to keep all configuration settings in one place (e.g. the |
|
Also the CouchDB database files are located under |
| domain: 127.0.0.1 | ||
| } | ||
| clouseau: { | ||
| dir: dev/lib/node1/indexes |
There was a problem hiding this comment.
Gabor's point aside for a moment, this path needs to use the ctx["devdir"] variable rather than assume 'dev/'
There was a problem hiding this comment.
Right. On top of that, if we wanted to regenerate the configuration file for the sake of stay in sync with the contents of ctx["devdir"] that could easily overwrite the local changes. The purpose of this template is to lay down the configuration file if it does not exist, not to always keep that updated. This also showcases that ad-hoc overrides via Java properties are better suited for this scenario.
|
I agree with gabor that the -Dclouseau.dir behaviour in clouseau should be restored. |
|
See https://github.com/apache/couchdb/blob/main/dev/run#L888 where we already pass a per-instance value to clouseau, it's just clouseau 3.0 ignores it. I think configuration was changed from https://commons.apache.org/proper/commons-configuration/ to whatever zio ships with, and which was configured as follows; namely, that it would read from a file but could be overridden by Java system properties. |
|
The configuration is managed by the Typesafe Config library where Java properties mapping hence ad-hoc overrides are possible. |
Overview
The default Clouseau configuration in
./dev/runresults in all Clouseau instances trying to write index files to the same folder. That creates a race condition. Observable symptom of the race condition is the followingcurloutput:Output:
Checklist
rel/overlay/etc/default.inisrc/docsfolder